Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extend File System Class #215

Merged
merged 32 commits into from
Jan 10, 2025
Merged

Extend File System Class #215

merged 32 commits into from
Jan 10, 2025

Conversation

namithj
Copy link
Contributor

@namithj namithj commented Nov 29, 2024

Extend File System Class

Pull Request

What changed?

(Please list the changes you made...)

Why did it change?

(Please list the reasons you made the changes...)

Did you fix any specific issues?

(Please tag any specific issues here...)

CERTIFICATION

By opening this pull request, I do agree to abide by the Code of Conduct and be bound by the terms of the Contribution Guidelines in effect on the date and time of my contribution as proven by the revision information in GitHub.

@namithj namithj requested a review from costdev November 29, 2024 15:02
@namithj
Copy link
Contributor Author

namithj commented Nov 29, 2024

@costdev Can you take a look here before I go too far and see if there are any issues with this approach.

includes/class-debug.php Outdated Show resolved Hide resolved
Copy link
Contributor

@costdev costdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the ping @namithj! I don't see any immediate issues.

I understand the desire to extend WP_Filesystem_Direct as this is indeed extending the underlying functionality, and there's no need to, for example, repeat the contents of WP_Filesystem_Direct::chmod() elsewhere. I think it's fine to keep going.

What other methods do you intend to introduce to this class?

@namithj
Copy link
Contributor Author

namithj commented Nov 30, 2024

I will be overriding the get_contents_array function to introduce a two new parameters (no of lines to read and read direction) which will let us read from bottom up and also modify it to read via file pointer and iterate over the required no of lines instead of pulling the whole content into memory as it does now.

The Read Routine
@namithj namithj marked this pull request as ready for review December 4, 2024 14:54
PHP Doc Alignment
includes/class-debug.php Outdated Show resolved Hide resolved
@namithj
Copy link
Contributor Author

namithj commented Dec 20, 2024

I will try and push the changes today so that we can merge this in

includes/class-debug.php Outdated Show resolved Hide resolved
includes/class-debug.php Outdated Show resolved Hide resolved
includes/class-debug.php Outdated Show resolved Hide resolved
Co-authored-by: Colin Stewart <[email protected]>
Signed-off-by: Namith Jawahar <[email protected]>
@costdev
Copy link
Contributor

costdev commented Jan 8, 2025

@namithj I'm about to push test updates. There is one expected failure, which requires two source changes in the PR to fix. Once GitHub Actions fails to demonstrate the issue, I'll push the two source changes to verify the fix.

@costdev
Copy link
Contributor

costdev commented Jan 8, 2025

🤔 Seems there's some failures happening with setting up the tests. That's... new. 🤨

Subversion was removed from GitHub Actions' default packages for Ubuntu 24.

The tests installer uses Subversion internally. This changes installs Subversion.
@costdev
Copy link
Contributor

costdev commented Jan 8, 2025

@costdev
Copy link
Contributor

costdev commented Jan 8, 2025

Sweet. There's the expected test failure. Pushing source changes to verify the fix now.

@costdev
Copy link
Contributor

costdev commented Jan 8, 2025

@namithj GitHub Actions passing 🎉

Can you pull down the latest changes in the PR and do some testing in the dashboard to make sure everything still works as you expect it to?

@namithj
Copy link
Contributor Author

namithj commented Jan 9, 2025

Everything looks good.

@costdev
Copy link
Contributor

costdev commented Jan 9, 2025

I have a few more minor test updates to make for correctness, then I think we'll be ready to merge after that.

@costdev
Copy link
Contributor

costdev commented Jan 10, 2025

@namithj I think that's me done with tests for this one - for now at least. I'm happy to merge this now. What do you think?

@namithj
Copy link
Contributor Author

namithj commented Jan 10, 2025

Merging

@namithj namithj merged commit 53ae2ce into aspirepress:main Jan 10, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants